Skip to content

Feat | Add OpenAPI documentation for OAuth2UserRegistrationRequestApiController#108

Merged
smarcet merged 2 commits into
mainfrom
feat/openapi----api-v1---oauth2userregistrationrequestapicontroller
May 27, 2026
Merged

Feat | Add OpenAPI documentation for OAuth2UserRegistrationRequestApiController#108
smarcet merged 2 commits into
mainfrom
feat/openapi----api-v1---oauth2userregistrationrequestapicontroller

Conversation

@matiasperrone-exo
Copy link
Copy Markdown
Contributor

@matiasperrone-exo matiasperrone-exo commented Feb 11, 2026

Tasks:

Ref: https://app.clickup.com/t/86b8e6k7j

Endpoints:

Method Endpoint Method Name
GET, HEAD api/v1/user-registration-requests getAll
OPTIONS, POST api/v1/user-registration-requests register
PUT api/v1/user-registration-requests/{id} update

Summary by CodeRabbit

  • Documentation
    • Added comprehensive OpenAPI/Swagger documentation for user registration endpoints, including request schemas, response schemas, and OAuth2 security configuration for better API integration guidance.

@matiasperrone-exo matiasperrone-exo self-assigned this Feb 11, 2026
@matiasperrone-exo matiasperrone-exo force-pushed the feat/openapi----api-v1---oauth2userregistrationrequestapicontroller branch from 730fc17 to 4ed52be Compare February 11, 2026 22:34
@matiasperrone-exo matiasperrone-exo added the documentation Improvements or additions to documentation label Feb 12, 2026
@matiasperrone-exo matiasperrone-exo force-pushed the feat/openapi----api-v1---oauth2userregistrationrequestapicontroller branch from 4ed52be to ffb187b Compare February 12, 2026 19:21
@smarcet smarcet force-pushed the main branch 2 times, most recently from ae79f5e to 4b5b726 Compare February 12, 2026 20:00
@matiasperrone-exo matiasperrone-exo force-pushed the feat/openapi----api-v1---oauth2userregistrationrequestapicontroller branch 7 times, most recently from ac9957d to 8d6b3eb Compare February 18, 2026 20:47
Copy link
Copy Markdown

@martinquiroga-exo martinquiroga-exo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Copy Markdown
Contributor

@caseylocker caseylocker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@matiasperrone-exo matiasperrone-exo force-pushed the feat/openapi----api-v1---oauth2userregistrationrequestapicontroller branch from 8d6b3eb to efff138 Compare March 17, 2026 19:28
@matiasperrone-exo
Copy link
Copy Markdown
Contributor Author

Rebased.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 17, 2026

Warning

Review limit reached

@matiasperrone-exo, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 54 minutes and 20 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: b8d1b006-026d-4b5a-9863-c2673bb49669

📥 Commits

Reviewing files that changed from the base of the PR and between efff138 and 7177662.

📒 Files selected for processing (7)
  • app/Http/Controllers/Api/OAuth2/OAuth2UserRegistrationRequestApiController.php
  • app/Swagger/Models/UserRegistrationRequestSchema.php
  • app/Swagger/OAuth2UserRegistrationRequestApiControllerSchemas.php
  • app/Swagger/Requests/CreateUserRegistrationRequestRequestSchema.php
  • app/Swagger/Requests/UpdateUserRegistrationRequestRequestSchema.php
  • app/Swagger/Requests/UserRegistrationRequestFieldsSchema.php
  • app/Swagger/Security/OAuth2UserRegistrationRequestApiControllerSecurityScheme.php
📝 Walkthrough

Walkthrough

This pull request adds comprehensive OpenAPI/Swagger documentation to the OAuth2 user registration API endpoints. It introduces schema classes for request payloads, response models, and security definitions, along with OpenAPI annotations to an existing controller, without altering business logic or control flow.

Changes

Cohort / File(s) Summary
Controller API Documentation
app/Http/Controllers/Api/OAuth2/OAuth2UserRegistrationRequestApiController.php
Adds OpenAPI annotations for three endpoints (GET, POST, PUT) including operation details, security requirements, parameters, request bodies, and response definitions.
Response & Model Schemas
app/Swagger/Models/UserRegistrationRequestSchema.php, app/Swagger/OAuth2UserRegistrationRequestApiControllerSchemas.php
Defines OpenAPI schemas for user registration request models and paginated response structures with properties like email, name fields, country, and password link.
Request Body Schemas
app/Swagger/Requests/CreateUserRegistrationRequestRequestSchema.php, app/Swagger/Requests/UpdateUserRegistrationRequestRequestSchema.php, app/Swagger/Requests/UserRegistrationRequestFieldsSchema.php
Introduces reusable request schemas for create and update operations, with shared field definitions for name, company, and country fields.
OAuth2 Security Scheme
app/Swagger/Security/OAuth2UserRegistrationRequestApiControllerSecurityScheme.php
Defines OAuth2 authorization code flow security scheme with registration scope.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 Hops with joy through specs so fine,
Documentation now shines divine,
Schemas neat in every place,
API docs with swagger grace!
🌟✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: adding OpenAPI documentation for a specific controller. It directly matches the changeset which adds comprehensive OpenAPI annotations across multiple schema files and controller methods.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/openapi----api-v1---oauth2userregistrationrequestapicontroller

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Copy Markdown

📘 OpenAPI / Swagger preview

➡️ https://OpenStackweb.github.io/openstackid/openapi/pr-108/

This page is automatically updated on each push to this PR.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
app/Swagger/OAuth2UserRegistrationRequestApiControllerSchemas.php (1)

1-6: Consider adding the license header for consistency.

Similar to UserRegistrationRequestSchema.php, this file is missing the Apache 2.0 license header present in other schema files.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/Swagger/OAuth2UserRegistrationRequestApiControllerSchemas.php` around
lines 1 - 6, Add the standard Apache 2.0 license header to the top of this file
(the same header used in UserRegistrationRequestSchema.php and other schema
files) so the namespace declaration (namespace App\Swagger\schemas) and the use
statement (use OpenApi\Attributes as OA) are preceded by the license block;
ensure the header text exactly matches the project's existing Apache 2.0 header
for consistency.
app/Swagger/Models/UserRegistrationRequestSchema.php (1)

1-6: Consider adding the license header for consistency.

Other schema files in this PR include the Apache 2.0 license header. This file is missing it, which creates inconsistency across the codebase.

📝 Suggested fix
 <?php

 namespace App\Swagger\schemas;
+/**
+ * Copyright 2025 OpenStack Foundation
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ **/

 use OpenApi\Attributes as OA;
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/Swagger/Models/UserRegistrationRequestSchema.php` around lines 1 - 6, Add
the standard Apache 2.0 license header to the top of this file to match other
schema files; open the UserRegistrationRequestSchema.php file (namespace
App\Swagger\schemas) and insert the same multi-line Apache 2.0 comment block
used in other Swagger schema files before the opening <?php so the file header
is consistent with the rest of the PR.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@app/Swagger/Models/UserRegistrationRequestSchema.php`:
- Around line 1-6: Add the standard Apache 2.0 license header to the top of this
file to match other schema files; open the UserRegistrationRequestSchema.php
file (namespace App\Swagger\schemas) and insert the same multi-line Apache 2.0
comment block used in other Swagger schema files before the opening <?php so the
file header is consistent with the rest of the PR.

In `@app/Swagger/OAuth2UserRegistrationRequestApiControllerSchemas.php`:
- Around line 1-6: Add the standard Apache 2.0 license header to the top of this
file (the same header used in UserRegistrationRequestSchema.php and other schema
files) so the namespace declaration (namespace App\Swagger\schemas) and the use
statement (use OpenApi\Attributes as OA) are preceded by the license block;
ensure the header text exactly matches the project's existing Apache 2.0 header
for consistency.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 5844c027-aab7-4fef-97a9-adba2e69d618

📥 Commits

Reviewing files that changed from the base of the PR and between 6d23f7f and efff138.

📒 Files selected for processing (7)
  • app/Http/Controllers/Api/OAuth2/OAuth2UserRegistrationRequestApiController.php
  • app/Swagger/Models/UserRegistrationRequestSchema.php
  • app/Swagger/OAuth2UserRegistrationRequestApiControllerSchemas.php
  • app/Swagger/Requests/CreateUserRegistrationRequestRequestSchema.php
  • app/Swagger/Requests/UpdateUserRegistrationRequestRequestSchema.php
  • app/Swagger/Requests/UserRegistrationRequestFieldsSchema.php
  • app/Swagger/Security/OAuth2UserRegistrationRequestApiControllerSecurityScheme.php

Comment thread app/Http/Controllers/Api/OAuth2/OAuth2UserRegistrationRequestApiController.php Outdated
Copy link
Copy Markdown
Collaborator

@smarcet smarcet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@matiasperrone-exo please review

@github-actions
Copy link
Copy Markdown

📘 OpenAPI / Swagger preview

➡️ https://OpenStackweb.github.io/openstackid/openapi/pr-108/

This page is automatically updated on each push to this PR.

@matiasperrone-exo matiasperrone-exo force-pushed the feat/openapi----api-v1---oauth2userregistrationrequestapicontroller branch from 8524568 to 7177662 Compare May 27, 2026 16:36
@matiasperrone-exo
Copy link
Copy Markdown
Contributor Author

@smarcet all the comments were addressed and the description of the PR too with the correct endpoints and methods.

@matiasperrone-exo matiasperrone-exo requested a review from smarcet May 27, 2026 16:37
@github-actions
Copy link
Copy Markdown

📘 OpenAPI / Swagger preview

➡️ https://OpenStackweb.github.io/openstackid/openapi/pr-108/

This page is automatically updated on each push to this PR.

Copy link
Copy Markdown
Collaborator

@smarcet smarcet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@smarcet smarcet merged commit 5ad8c11 into main May 27, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants